﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.IO;

namespace WebSreviceTest
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            string path = "c:\\test.jpg";
            FileInfo fileInf = new FileInfo(path);
            System.IO.FileStream fs = new System.IO.FileStream(path, System.IO.FileMode.Open, System.IO.FileAccess.Read);
            System.IO.BinaryReader br = new System.IO.BinaryReader(fs);
            Byte[] bytes = br.ReadBytes((Int32)fs.Length);

            //pl.studentlive.nosoifighters.DataProviderService ws = new pl.studentlive.nosoifighters.DataProviderService();
            localhost.DataProviderService ws = new localhost.DataProviderService();
            //var a = ws.GetAvailableDiseases();
            ws.uploadImage(bytes);
            MessageBox.Show("plik wyslany");
        }


    }
}
